jinja2

! Configuration File for keepalived

global_defs {
   router_id {{ router_id }}
}

vrrp_script check_haproxy {
   script "/etc/keepalived/check_haproxy.sh"
   interval 1
}

vrrp_instance haproxy {
    state {{ state }}
    interface ens33
    virtual_router_id 88
    priority {{ priority }}
    advert_int 1
    authentication {
        auth_type PASS
        auth_pass 123456
    }
    virtual_ipaddress {
        192.168.81.100
    }
}
